package com.cc.web.vo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.cc.infrastructure.special.dto.SupplyDo;
import com.cc.infrastructure.db.SupplyDb;


@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel("前端传递参数")
public class SupplyVo {

  /**
   *
   **/
  @ApiModelProperty("")
  private String id;
  /**
   *
   **/
  @ApiModelProperty("")
  private String name;

  public static SupplyVo convertSupplyVoBySupplyDo(SupplyDo supplyDo) {
    SupplyVo supplyvo = new SupplyVo();
    supplyvo.setId(supplyDo.getId());
    supplyvo.setName(supplyDo.getName());
    return supplyvo;
  }

  public static SupplyVo convertSupplyVoBySupplyDo(SupplyDb supplyDb) {
    SupplyVo supplyvo = new SupplyVo();
    supplyvo.setId(supplyDb.getId());
    supplyvo.setName(supplyDb.getName());
    return supplyvo;
  }
}